package com.webinsky.web.utils;

import java.io.UnsupportedEncodingException;

import javax.mail.MessagingException;

import com.webinsky.common.utils.EmailUtils;
import com.webinsky.common.utils.EmailUtils.EmailContent;

public class EmailMessage implements Message {
	
	private EmailContent content;

	public EmailMessage(EmailContent content){
		this.content = content;
	}
	
	
	@Override
	public void sendMessage() {
		try {
			EmailUtils.sendMail(content);
		} catch (UnsupportedEncodingException | MessagingException e) {
			e.printStackTrace();
		}
	}

}
